package com.ruoyi.project.hissystem.domain;

import com.ruoyi.framework.aspectj.lang.annotation.Excel;
import com.ruoyi.framework.web.domain.BaseEntity;
import java.util.Objects;

/**
 * @author : 杨磊
 * @date : 9:54 2021/8/18
 */
public class HisUser extends BaseEntity {

    @Excel(name = "用户序号", cellType = Excel.ColumnType.NUMERIC, prompt = "用户编号")
    private  Long userId;

    @Excel(name = "用户名称")
    private String userName;

    @Excel(name = "所属部门", type = Excel.Type.IMPORT)
    private  String userDepartment;

    @Excel(name = "手机号码")
    private String userPhone;

    @Excel(name = "用户性别", readConverterExp = "0=男,1=女,2=未知")
    private String userSex;

    @Excel(name = "年龄")
    private  String  age;

    @Excel(name = "是否排班" ,readConverterExp = "Y=是,N=否")
    private  String userClass;

    @Excel(name = "级别")
    private String userLevel;

    @Excel(name = "学历背景")
    private String userBackground;

    /** 密码 */
    private String password;

    //部门(科室)id （外键）
    private Integer departId;

    //科室信息
    private  HisDepartment hisDepartment;
    /** 帐号状态（0正常 1停用） */
    @Excel(name = "帐号状态", readConverterExp = "0=正常,1=停用")
    private String status;

    @Override
    public String toString() {
        return "HisUser{" +
              "userId=" + userId +
              ", userName='" + userName + '\'' +
              ", userDepartment='" + userDepartment + '\'' +
              ", userPhone='" + userPhone + '\'' +
              ", userSex='" + userSex + '\'' +
              ", age='" + age + '\'' +
              ", userClass='" + userClass + '\'' +
              ", userLevel='" + userLevel + '\'' +
              ", userBackground='" + userBackground + '\'' +
              ", password='" + password + '\'' +
              ", departmentId=" + departId +
              ", hisDepartment=" + hisDepartment +
              ", status='" + status + '\'' +
              '}';
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        HisUser hisUser = (HisUser) o;
        return Objects.equals(userId, hisUser.userId) && Objects.equals(userName, hisUser.userName) && Objects.equals(userDepartment, hisUser.userDepartment) && Objects.equals(userPhone, hisUser.userPhone) && Objects.equals(userSex, hisUser.userSex) && Objects.equals(age, hisUser.age) && Objects.equals(userClass, hisUser.userClass) && Objects.equals(userLevel, hisUser.userLevel) && Objects.equals(userBackground, hisUser.userBackground) && Objects.equals(password, hisUser.password) && Objects.equals(departId, hisUser.departId) && Objects.equals(hisDepartment, hisUser.hisDepartment) && Objects.equals(status, hisUser.status);
    }

    @Override
    public int hashCode() {
        return Objects.hash(userId, userName, userDepartment, userPhone, userSex, age, userClass, userLevel, userBackground, password, departId, hisDepartment, status);
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getUserDepartment() {
        return userDepartment;
    }

    public void setUserDepartment(String userDepartment) {
        this.userDepartment = userDepartment;
    }

    public String getUserPhone() {
        return userPhone;
    }

    public void setUserPhone(String userPhone) {
        this.userPhone = userPhone;
    }

    public String getUserSex() {
        return userSex;
    }

    public void setUserSex(String userSex) {
        this.userSex = userSex;
    }

    public String getAge() {
        return age;
    }

    public void setAge(String age) {
        this.age = age;
    }

    public String getUserClass() {
        return userClass;
    }

    public void setUserClass(String userClass) {
        this.userClass = userClass;
    }

    public String getUserLevel() {
        return userLevel;
    }

    public void setUserLevel(String userLevel) {
        this.userLevel = userLevel;
    }

    public String getUserBackground() {
        return userBackground;
    }

    public void setUserBackground(String userBackground) {
        this.userBackground = userBackground;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public Integer getDepartId() {
        return departId;
    }

    public void setDepartId(Integer departId) {
        this.departId = departId;
    }

    public HisDepartment getHisDepartment() {
        return hisDepartment;
    }

    public void setHisDepartment(HisDepartment hisDepartment) {
        this.hisDepartment = hisDepartment;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public HisUser(Long userId, String userName, String userDepartment, String userPhone, String userSex, String age, String userClass, String userLevel, String userBackground, String password, Integer departId, HisDepartment hisDepartment, String status) {
        this.userId = userId;
        this.userName = userName;
        this.userDepartment = userDepartment;
        this.userPhone = userPhone;
        this.userSex = userSex;
        this.age = age;
        this.userClass = userClass;
        this.userLevel = userLevel;
        this.userBackground = userBackground;
        this.password = password;
        this.departId = departId;
        this.hisDepartment = hisDepartment;
        this.status = status;
    }

    public HisUser() {
    }
}
